package com.she.iiicoursecenter.activity.tab1_infomation;

import android.os.Bundle;
import android.widget.TextView;

import com.she.iiicoursecenter.R;
import com.she.iiicoursecenter.activity.template.TemplateActivity;
import com.she.iiicoursecenter.view.tab1.Tab1_CourseReserveView;
import com.she.iiicoursecenter.view.tab1.Tab1_CourseSingleView;
import com.she.iiicoursecenter.view.tab1.Tab1_MainView;

public class Tab1_CourseReserve extends TemplateActivity {
	//
	//
	private Tab1_CourseReserveView	mCourseRceserveView;

	public Tab1_CourseReserve() {
		// TODO Auto-generated constructor stub
	}

	@Override
	protected void onCreate(Bundle savedInstanceState) {
		// TODO Auto-generated method stub
		super.onCreate(savedInstanceState);
				
		mCourseRceserveView = new Tab1_CourseReserveView(this);
		
		// get bundle from previous...
		Bundle bundle = this.getIntent().getExtras();

		// test only!!!
		String code = bundle.getString("code");
		int contentId = bundle.getInt("contentId");
		String name = bundle.getString("name");
		
		((TextView)mCourseRceserveView.findViewById(R.id.tab1_reserve_itemname)).setText(getApp().getItemName());
		((TextView)mCourseRceserveView.findViewById(R.id.tab1_reserve_contentid)).setText(code);
		((TextView)mCourseRceserveView.findViewById(R.id.tab1_reserve_contentname)).setText(name);
		//
		setView(mCourseRceserveView);
		setContentView(mCourseRceserveView);		
		
		mCourseRceserveView.setContentID(contentId);
	}

	@Override
	protected void onStart() {
		// TODO Auto-generated method stub
		super.onStart();
	}

	@Override
	protected void onResume() {
		// TODO Auto-generated method stub
		super.onResume();
	}

	@Override
	protected void onPause() {
		// TODO Auto-generated method stub
		super.onPause();
	}

	@Override
	protected void onStop() {
		// TODO Auto-generated method stub
		super.onStop();
	}

	@Override
	protected void onDestroy() {
		// TODO Auto-generated method stub
		super.onDestroy();
	}

	@Override
	public void onAttachedToWindow() {
		// TODO Auto-generated method stub
		super.onAttachedToWindow();
	}

	@Override
	public void onDetachedFromWindow() {
		// TODO Auto-generated method stub
		super.onDetachedFromWindow();
	}
	
}
